package model;

import java.util.HashMap;

/**
 * Filter interface
 *
 */
public interface FilterImp 
{
	
	/**
	 * Checks the provided an email against this filter and returns a boolean indicating whether the email is from a specific sender.
	 * @param arrivedEmail is the the email (String type) to check against this filter.
	 * @param sender  is the string containing the sender's email ID.
	 * @return Returns boolean indicator indicating if the the email matches the filter criteria.
	 */
	public boolean isFromSender(HashMap<String, String> arrivedEmail, String sender);
	
	/**
	 * Checks the provided an email against this filter and returns a boolean indicating whether the email is from a specific domain.
	 * @param arrivedEmail is the the email (String type) to check against this filter.
	 * @param domain is the string containing the sender's domain.
	 * @return Returns boolean indicator indicating if the the email matches the filter criteria.
	 */
	public boolean isFromDomain(HashMap<String, String> arrivedEmail, String domain);
	
	/**
	 Checks the provided an email against this filter and returns a boolean indicating whether the email has the words provided.
	 * @param arrivedEmail is the the email (String type) to check against this filter.
	 * @return Returns boolean indicator indicating if the the email matches the filter criteria.
	 */
	public boolean hasWords(HashMap<String, String> arrivedEmail, String wordsSeparatedByCommas);

	/**
	 * @return Returns a boolean indicating of the filter is active.
	 */
	public boolean isEnabled();
	
	/**
	 * @param activation a parameter to set activation state of the filter.
	 */
	public void setActivation(boolean activation);

}
